$(function () {
  var orderInfoByUser = new Vue({
    el:"#userOrderInfo",
    data:{
      orderInfoList:[]
    },
    methods:{
      getUserOrderInfo:function () {
        var that = this;
        axios.get("../api/order/getOrderByUser",
            {headers:{'token':localStorage.getItem("token")}}).then(function(response){
          if (response.data.code!="0"){
            alert(response.data.msg);
            return;
          }
          that.orderInfoList = response.data.data;
          console.log(response)
          console.log(response.data.data.list)
        }).catch(function(err){
          console.log(err);
        });
      }
    },
    created(){
      this.getUserOrderInfo();
    }
  })

  var getTokenVue = new Vue({
    el:"#getToken",
    data:{
      token:localStorage.getItem("token")
    }
    ,methods:{

    }
  })
});